Conversation
…erators, translatable labels
BREAKING CHANGE: actions are now named strings (create, approve, …)
instead of single letters (r, w, d). Permission string format uses
'/' (AND) and '|' (OR) separators. Scope ownership is strict.
Core
────
- actions per scope in PERMISSION_PRESET["actions"] with implies
hierarchy and translatable labels via gettext_lazy
- format: scope:action1/action2 (AND) | scope:action1|action2 (OR)
- ScopePermission respects / |; ScopeAnyActionPermission always OR
- ACCESS_SCOPES supports strings or {key, label} dicts with _()
- strict scope ownership: duplicate → ImproperlyConfigured
- module self-configures via permissions/permissions.py
- ACCESS_MANAGER_SCOPE defaults to 'access'
API
───
- GET /api/access/scopes → [{key, label}] (NEW)
- GET /api/access/scopes/{scope}/actions → [{key, label}] (NEW)
i18n
────
- django.po/.mo: French labels for built-in actions & scope
DB
──
- migration 0010: ArrayField max_length 5→50
Tests & docs
────────────
- all tests migrated to named actions + labels + scope conflicts
- docs/permissions.md rewritten, README updated
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…erators, translatable labels
BREAKING CHANGE: actions are now named strings (create, approve, …) instead of single letters (r, w, d). Permission string format uses '/' (AND) and '|' (OR) separators. Scope ownership is strict.
Core
────
API
───
i18n
────
DB
──
Tests & docs
────────────